import request from '@/utils/request';

// 查询家族文化列表
export function listCulture(query) {
  return request({
    url: '/genealogy/culture/list',
    method: 'get',
    params: query
  });
}

// 查询家族文化详细
export function getCulture(id) {
  return request({
    url: `/genealogy/culture/${id}`,
    method: 'get'
  });
}

// 新增家族文化
export function addCulture(data) {
  return request({
    url: '/genealogy/culture',
    method: 'post',
    data: data
  });
}

// 修改家族文化
export function updateCulture(data) {
  return request({
    url: '/genealogy/culture',
    method: 'put',
    data: data
  });
}

// 删除家族文化
export function delCulture(id) {
  return request({
    url: `/genealogy/culture/${id}`,
    method: 'delete'
  });
}

// 上传家族文化图片
export function uploadCultureImage(data) {
  return request({
    url: '/file/upload',
    method: 'post',
    data: data,
    headers: {
      'Content-Type': 'multipart/form-data'
    }
  });
} 